function getTitle(){
    let res = {};
    let d = [];
    let rescode = getResCode();
    d.push({
        title:'<big><big><h1 style="text-align:center"><font color="#45ddff">搜优图</font></h1></big></big>',
        col_type:"rich_text"
    });
    let titlelist1 = parseDomForArray(rescode,".menu-list-content&&li");
    titlelist1.shift();
    let titlelist2 = parseDomForArray(rescode,".txtmenu&&a");
    let titlelist = titlelist1.concat(titlelist2);
    titlelist.splice(8,1);
    for(let i=0;i<titlelist.length;i++){
       let col_type="text_3";
        if(i<2){
            col_type="text_center_1";
        }
        d.push({
            title:parseDomForHtml(titlelist[i],"a&&Text"),
            url:"hiker://empty#"+parseDomForHtml(titlelist[i],"a&&href")+"#fypage",
            col_type:col_type
        })
        if(i ==1 ||(i-1)%3 == 0){
            for(let t =0;t<3;t++){
                d.push({
                    col_type:"big_blank_block"
                })
            }
        }
    }
    res.data = d;
    setResult(res);
}

function getPiclist(){
    let res = {};
    let d = [];
    let page = MY_URL.split("#")[2];
    let rescode = fetch(MY_URL.split("#")[1]);
    let catagorylist = parseDomForArray(rescode,".r&&.cl&&li");
    if(page == 1){
        for(let i=0;i<catagorylist.length;i++){
            let title = parseDomForHtml(catagorylist[i],"a&&Text");
            d.push({
                title:title,
                url:$(parseDomForHtml(catagorylist[i],"a&&href")).lazyRule((obj) => {
                    let picurl = input;
                    let pictitle = obj.word;
                    putVar("souutu_picurl",picurl);
                    putVar("souutu_title",pictitle);
                    refreshPage();
                    // "toast://切换成功"
                },{word:title}),
                col_type:"text_4"
            })
        }
    }
    let fetchpage;
    if (page == 1){
        fetchpage = ""
    }else{
        fetchpage = "_"+page
    }
    let fetchurl = getVar("souutu_picurl",MY_URL)+"index"+fetchpage+".html";
    let fetchcode = fetch(fetchurl,{});
    let piclist = parseDomForArray(fetchcode,".work-list-box&&.card-box");
    if(page == 1){
        d.push({
                col_type:"line_blank"
            },{
                title:"‘‘当前分类："+getVar("souutu_title","无")+"’’",
                url:"hiker://empty@lazyRule=.js:'toast://别点我，再点，我直接原地爆炸'",
                col_type:"text_center_1"
        });
    }
    for(let j=0;j<piclist.length;j++){
        if(piclist[j].indexOf("listPimgsw") != -1){
            let picnuminfo = parseDomForHtml(piclist[j],".listPimgsw&&Text");
            d.push({
                title:"【套图】"+parseDomForHtml(piclist[j],".card-info-title&&Text"),
                pic_url:parseDomForHtml(piclist[j],"img&&lazysrc")+"@Referer=https://www.souutu.com/",
                desc:parseDomForHtml(piclist[j],".card-item&&Text"),
                url:$(parseDomForHtml(piclist[j],"a,0&&href")).rule((obj) => {
                    let res = {};
                    let d = [];
                    let rescode = getResCode();
                    d.push({
                        title:'<h3 style="text-align:center"><font color="#38ffdd">'+obj.word+'</font></h3>',
                        col_type:'rich_text',
                        url:"toast://点这干啥？"
                    },{
                        col_type:"line"
                    });
                    let picnum = obj.word.match(/\d+(.\d+)?/g)[0];
                    let fetchurls = [];
                    for(let n=0;n<picnum;n++){
                        fetchurls.push({
                            url:MY_URL.replace(".html","_"+(n+1)+".html"),
                            options:{
                                headers:{"User-Agent":PC_UA}
                            }
                        });
                    }
                    let batchcode = batchFetch(fetchurls);
                    try{
                        batchcode.map( res => {
                            let bigpic = parseDomForHtml(res,'.showcontw&&img,0&&src').split("jpg")[0]+"jpg@Referer=https://www.souutu.com/";
                            d.push({
                                pic_url:bigpic,
                                url:bigpic,
                                col_type:"pic_1_full"
                            })
                        })
                    }catch(e){
                        d.push({
                            title:"木有了",
                            url:"toast://真木有了",
                            col_type:"text_center_1"
                        })
                    }
                    res.data = d;
                    setResult(res);
                },{word:picnuminfo}),
                col_type:"movie_2"
            })
        }else{
            d.push({
                title:parseDomForHtml(piclist[j],".card-info-title&&Text"),
                pic_url:parseDomForHtml(piclist[j],"img&&lazysrc")+"@Referer=https://www.souutu.com/",
                desc:parseDomForHtml(piclist[j],".card-item&&Text"),
                url:parseDomForHtml(piclist[j],"img&&lazysrc").split("jpg")[0]+"jpg@Referer=https://www.souutu.com/@lazyRule=.js:input",
                col_type:"movie_2"
            })
        }
    }

    res.data = d;
    setResult(res);
}

function getPiclist1(){
    let res = {};
    let d = [];
    let page = MY_URL.split("#")[2];
    let rescode = fetch(MY_URL.split("#")[1]);
    let catagorylist = parseDomForArray(rescode,".z&&a");
    if(page == 1){
        for(let i=0;i<catagorylist.length;i++){
            let title = parseDomForHtml(catagorylist[i],"a&&Text");
            d.push({
                title:title,
                url:$(parseDomForHtml(catagorylist[i],"a&&href")).lazyRule((obj) => {
                    let picurl = input;
                    let pictitle = obj.word;
                    putVar("souutu_picurl1",picurl);
                    putVar("souutu_title1",pictitle);
                    refreshPage();
                    "toast://切换成功"
                },{word:title}),
                col_type:"text_4"
            })
        }
    }
    let fetchpage;
    if (page == 1){
        fetchpage = ""
    }else{
        fetchpage = "_"+page
    }
    let fetchurl = getVar("souutu_picurl1",MY_URL)+"index"+fetchpage+".html";
    let fetchcode = fetch(fetchurl,{});
    let piclist = parseDomForArray(fetchcode,".work-list-box&&.card-box");
    if(page == 1){
        d.push({
                col_type:"line_blank"
            },{
                title:"‘‘当前分类："+getVar("souutu_title1","无")+"’’",
                url:"hiker://empty@lazyRule=.js:'toast://别点我，再点，我直接原地爆炸'",
                col_type:"text_center_1"
        });
    }
    for(let j=0;j<piclist.length;j++){
        d.push({
            title:parseDomForHtml(piclist[j],".card-info-title&&Text"),
            pic_url:parseDomForHtml(piclist[j],"img&&lazysrc")+"@Referer=https://www.souutu.com/",
            desc:parseDomForHtml(piclist[j],".card-item&&Text"),
            url:$(parseDomForHtml(piclist[j],"a,0&&href")).rule(() => {
                    let res = {};
                    let d = [];
                    let rescode = getResCode();
                    let picnum = parseDomForHtml(rescode,".mlw,0&&Text");
                    if(/[^0-9/()]/.test(picnum) != true){
                        picnum = picnum.split("/")[1].match(/\d+(.\d+)?/g)[0];
                        d.push({
                            title:'<h3 style="text-align:center"><font color="#38ffdd">套图'+picnum+'张</font></h3>',
                            col_type:'rich_text',
                            url:"toast://点这干啥？"
                        },{
                            col_type:"line"
                        });
                        let fetchurls = [];
                        for(let n=0;n<picnum;n++){
                            fetchurls.push({
                                url:MY_URL.replace(".html","_"+(n+1)+".html"),
                                options:{
                                    headers:{"User-Agent":PC_UA}
                                }
                            });
                        }
                        let batchcode = batchFetch(fetchurls);
                        try{
                            batchcode.map( res => {
                                let bigpic = parseDomForHtml(res,'.morew&&a&&href')+"@Referer=https://www.souutu.com/";
                                d.push({
                                    pic_url:bigpic,
                                    url:bigpic,
                                    col_type:"pic_1_full"
                                })
                            })
                        }catch(e){
                            d.push({
                                title:"木有了",
                                url:"toast://真木有了",
                                col_type:"text_center_1"
                            })
                        }
                    }else{
                        let otherlist = parseDomForArray(rescode,".gaoxiaoz||.ptm||.ptw&&img");
                        for(let s=0;s<otherlist.length;s++){
                            d.push({
                                pic_url:parseDomForHtml(otherlist[s],"img&&src"),
                                url:parseDomForHtml(otherlist[s],"img&&src"),
                                col_type:"pic_1_full"
                            })
                        }
                    }
                    res.data = d;
                    setResult(res);
                }),
            col_type:"movie_2"
        })
    }
    res.data = d;
    setResult(res);
}


